package com.project.scheduled.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.project.scheduled.entity.TjDay1Log;
import com.project.scheduled.mapper.TjDay1LogMapper;
import com.project.scheduled.service.TjDay1LogService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.time.LocalDate;
import java.time.LocalDateTime;

@Service
@Slf4j
public class TjDay1LogServiceImpl extends ServiceImpl<TjDay1LogMapper, TjDay1Log> implements TjDay1LogService {
    @Transactional
    public void saveLog(Integer step, String dateDone, LocalDateTime dt, String desc1){
        log.info("保存日志开始 step:{},dateDone:{},dt:{},desc1:{}",step,dateDone,dt,desc1);
        TjDay1Log tjDay1Log = new TjDay1Log();
        tjDay1Log.setStep(step);
        tjDay1Log.setDateDone(dateDone);
        tjDay1Log.setDt(dt);
        tjDay1Log.setDesc1(desc1);
        this.save(tjDay1Log);
    }
}
